<#assign className = table.className>
<#assign classNameLower = className?uncap_first>
package ${basePackage}.dao;

import ${basePackage}.entity.${table.className};
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;

/**
 * <p>
 * ${table.remark} 持久层接口
 * </p>
 *
 * @author wangjin
 * @classname: ${className}
 * @description: ${table.remark} 持久层
 * @towork: none
 * @version: 1.0.0
 * @since ${.now?string('yyyy/MM/dd HH:mm')}
 */
@Repository
public interface ${table.className}Dao {
    
    /**
     * ${table.remark} 列表查询
     *
     * @param ${table.className?uncap_first} ${table.remark}实体类
     * @return ${table.className?uncap_first}集合
     */
    List<${table.className}> selectList(${table.className} ${table.className?uncap_first});

    /**
     * ${table.remark} 根据唯一索引查询
     *
     * @param ${table.className?uncap_first} ${table.remark}实体类
     * @return ${table.className?uncap_first}集合
     */
    ${table.className} findByUniqueKey(${table.className} ${table.className?uncap_first});

    /**
     * ${table.remark} 根据主键查询数据
     *
     * @param ${table.className?uncap_first} ${table.remark}实体类
     * @return ${table.className} 指定id的${table.remark}数据
     */
    ${table.className} findByPrimaryKey(${table.className} ${table.className?uncap_first});


    /**
     * ${table.remark} 新增
     *
     * @param ${table.className?uncap_first} ${table.remark}实体类
     * @return 受影响行数
     */
    int insert(${table.className} ${table.className?uncap_first});

    /**
     * ${table.remark} 根据主键更新
     *
     * @param ${table.className?uncap_first} ${table.remark}实体类
     * @return 受影响行数
     */
    int updateByPrimaryKey(${table.className} ${table.className?uncap_first});

    /**
     * ${table.remark} 根据条件更新
     *
     * @param ${table.className?uncap_first} ${table.remark}实体类
     * @return 受影响行数
     */
    int updateByCondition(${table.className} ${table.className?uncap_first});

    /**
     * ${table.remark} 根据主键删除数据
     *
     * @param ${table.className?uncap_first} ${table.remark}实体类
     * @return 受影响行数
     */
    int delete(${table.className} ${table.className?uncap_first});

    /**
     * ${table.remark} 根据主键批量删除数据
     *
     * @param ${table.className?uncap_first} ${table.remark}实体类
     * @return 受影响行数
     */
    int deleteByBatch(@Param("${table.className?uncap_first}List") List<${table.className}> ${table.className?uncap_first}List);
}
